package cn.gjxblog.core.event.spring.demo1;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.JUnit4;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

@RunWith(JUnit4.class)
public class TestEvent {
    @Test
    public void test(){
        AnnotationConfigApplicationContext annotationConfigApplicationContext = new AnnotationConfigApplicationContext("cn.gjxblog.core.event.spring.demo1");
        annotationConfigApplicationContext.publishEvent(new MyAppEvent("this is my event"));
    }
}
